package group.systemdesign.Controller;

import group.systemdesign.Pojo.User;
import group.systemdesign.Service.LoginService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

@RestController
public class LoginController {
    @Autowired
    private LoginService loginService;
    @GetMapping("login")
    public User login(String username, String password){
        return loginService.login(username,password);
    }
}